<p id="notice"><%= notice %></p>

<h2>  <%= @customer.name %> </h2>
<input type='hidden' id="customer_id" value="<%= @customer.id %>">
<h3>  Current Balance : <%= @customer.current_balance() %></h3>
<h3>  Opening Balance :<span id='initial_balance'> <%= @customer.initial_balance %></span></h3>

<% @holder = @customer%>
<% @debit_transactions=Transaction.find_all_by_giver_type_and_giver_id(@customer.class.name,@customer.id) %>
<% @credit_transactions=Transaction.find_all_by_receiver_type_and_receiver_id(@customer.class.name, @customer.id) %>
<%= render(:partial=>'transactions/form') %>
<script>
   setCreateTransactionType("Customer",$('#customer_id').val(),"Owner","1");
</script>
<%= render(:partial=>'transactions/list') %>

